package interfaces;

import java.awt.image.BufferedImage;
import java.io.File;

public abstract class Resizer {
	
	//define defaults
	private static final double DEFAULT_MAX_SCORE = 0.2;
	private static final Integer DEFAULT_MAX_NUM = null;
	private static final SeamCarve.ResizeDirection DEFAULT_DIRECTION = SeamCarve.horizontal;
	
	/**
	 * 
	 * @param width			final width
	 * @param height		final height
	 * @param original		original image
	 * @param maxScore		maximum score for any seam
	 * @param maxNum		maximum number of seams (null if no limit)
	 * @param direction		direction for seam resizing
	 * 
	 * @throws IllegalArgumentException		thrown on wrong arguments to Resizer
	 */
	public Resizer(int width, int height, BufferedImage original, 
			double maxScore, Integer maxNum, SeamCarve.ResizeDirection direction) throws IllegalArgumentException {
		
	}
	
	/**
	 * 
	 * @param width			final width
	 * @param height		final height
	 * @param original		original image
	 * 
	 * @throws IllegalArgumentException		thrown on wrong arguments to Resizer
	 */
	public Resizer(int width, int height, BufferedImage original) throws IllegalArgumentException {
		this(width, height, original, DEFAULT_MAX_SCORE, DEFAULT_MAX_NUM, DEFAULT_DIRECTION);
	}
	

	/** 
	 * @param heightWidthRatio	the new ratio of height to width (height / width)
	 * @param original			original image
	 * @param maxScore			maximum score for any seam
	 * @param maxNum			maximum number of seams (null if no limit)
	 * @param direction			direction for seam resizing
	 * @throws IllegalArgumentException		thrown on wrong arguments to Resizer
	 */
	public Resizer(double heightWidthRatio, BufferedImage original, 
			double maxScore, Integer maxNum, SeamCarve.ResizeDirection direction) throws IllegalArgumentException {
		
	}
	

	/**
	 * 
	 * @param heightWidthRatio	the new ratio of height to width (height / width)
	 * @param original			original image
	 * 
	 * @throws IllegalArgumentException		thrown on wrong arguments to Resizer
	 */
	public Resizer(double heightWidthRatio, BufferedImage original) throws IllegalArgumentException {
		this(heightWidthRatio, original, DEFAULT_MAX_SCORE, DEFAULT_MAX_NUM, DEFAULT_DIRECTION);
	}
	
	
	/** 
	 * passes image straight to SeamCarve without doing any other resize
	 * 
	 * 
	 * @param original			original image
	 * @param maxScore			maximum score for any seam
	 * @param maxNum			maximum number of seams (null if no limit)
	 * @param direction			direction for seam resizing
	 * @throws IllegalArgumentException		thrown on wrong arguments to Resizer
	 */
	public Resizer(BufferedImage original, double maxScore, Integer maxNum, 
			SeamCarve.ResizeDirection direction) throws IllegalArgumentException {
		
	}	
	
	
	
	
	/**
	 * @return		returns the finished image
	 */
	public abstract BufferedImage getFinalImage();
	
	/**
	 * @return		returns Files pointing to images animating the resize
	 */
	public abstract File[] getAnimPics();
	
	
	/**
	 * @return		returns the SeamCarve associated with the image
	 */
	public abstract SeamCarve getSeamCarve();
	
}